package by.grsu.hdm.media.implementations;

import by.grsu.hdm.media.MediaPlayer;
import by.grsu.hdm.media.file.MediaFile;

public class AudioAndVideoPlayer extends MediaPlayer {

	// TODO set somewhere current format
	//private MediaFile mediaFile;
	//private MediaPlayer mediaPlayer;

	@Override
	public void stop(MediaFile mediaFile) {
		Formats currentFormat = mediaFile.getCurrentFileFormat();
		switch (currentFormat) {
		case FLAC:
			System.out.println("FLAC is stopped");
			break;
		case MP_3:
			System.out.println("Mp3 is stopped");
			break;
		case MP_4:
			System.out.println("Mp4 is stopped");
			break;
		case WAV:
			System.out.println("WAV is stopped");
			break;
		default:
			System.out.println("Create a new mediafile");
			break;
		}
	}

	@Override
	public void pause(MediaFile mediaFile) {
		//Formats currentFormat = getCurrentFormat();
		Formats currentFormat = mediaFile.getCurrentFileFormat();
		switch (currentFormat) {
		case FLAC:
			System.out.println("FLAC is paused");
			break;
		case MP_3:
			System.out.println("Mp3 is paused");
			break;
		case MP_4:
			System.out.println("Mp4 is paused");
			break;
		case WAV:
			System.out.println("WAV is paused");
			break;
		default:
			System.out.println("Create a new mediafile");
			break;
		}
	}

	@Override
	public void play(MediaFile mediaFile) {
		Formats currentFormat = mediaFile.getCurrentFileFormat();
		//Formats currentFormat = getCurrentFormat();
		switch (currentFormat) {
		case FLAC:
			System.out.println("FLAC is being played");
			break;
		case MP_3:
			System.out.println("Mp3 is being played");
			break;
		case MP_4:
			System.out.println("Mp4 is being played");
			break;
		case WAV:
			System.out.println("WAV is being played");
			break;
		default:
			System.out.println("Create a new mediafile");
			break;
		}
	}

}
